feat: push notification CRUD — full set/get/list/delete implementation#20
Open
zeroasterisk wants to merge 1 commit intoactioncard:mainfrom
Open
feat: push notification CRUD — full set/get/list/delete implementation#20zeroasterisk wants to merge 1 commit intoactioncard:mainfrom
zeroasterisk wants to merge 1 commit intoactioncard:mainfrom
Conversation
Implements the full push notification config lifecycle:
- TaskStore behaviour: set_push_config/2, get_push_config/3,
list_push_configs/2, delete_push_config/3 (optional callbacks)
- ETS implementation: keyed by {task_id, config_id}
- JSONRPC handler callbacks: handle_set_push_config/3,
handle_get_push_config/4, handle_list_push_configs/3,
handle_delete_push_config/4 (optional, falls back to -32003)
- Server dispatch: wires all 4 PascalCase + legacy method names
- Client: create_push_config/3, get_push_config/4,
list_push_configs/3, delete_push_config/4
- Plug: auto-delegates to TaskStore when configured
- New structs: PushNotificationConfig, AuthenticationInfo
- New behaviour: PushNotificationSender with HTTP default impl
- JSON codec: encode/decode for push notification configs
- 37 new tests covering CRUD, JSON codec, and dispatch
Verified against a2a.proto HEAD (TaskPushNotificationConfig,
AuthenticationInfo, Get/List/Delete request types).
Part of actioncard#13 (A2A v1.0 Protocol Support)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #13 (A2A v1.0 Protocol Support)
What This PR Does
Replaces the current
-32003 PushNotificationNotSupportedErrorstubs with a full push notification config CRUD implementation, verified against the A2A proto.New Structs
A2A.PushNotificationConfig— maps toTaskPushNotificationConfigproto messageA2A.AuthenticationInfo— authentication details for push notification deliveryTaskStore (behaviour + ETS implementation)
set_push_config/2,get_push_config/3,list_push_configs/2,delete_push_config/3{task_id, config_id}for fast lookupJSONRPC Handler
handle_set_push_config/3,handle_get_push_config/4,handle_list_push_configs/3,handle_delete_push_config/4-32003(backward compatible)Server Dispatch
CreateTaskPushNotificationConfig→ store config, return configGetTaskPushNotificationConfig→ fetch by task_id + config_idListTaskPushNotificationConfigs→ list by task_idDeleteTaskPushNotificationConfig→ delete by task_id + config_idClient
create_push_config/3,get_push_config/4,list_push_configs/3,delete_push_config/4Plug Integration
PushNotificationSender Behaviour
A2A.PushNotificationSenderbehaviour withsend_notification/2callbackA2A.PushNotificationSender.HTTPimplementation (POSTs JSON with auth headers)JSON Codec
PushNotificationConfigandAuthenticationInfoTests
424 tests, 0 failures.
Fixes part of #13